surface: Drop group api
authorMatthias Clasen <mclasen@redhat.com>
Sat, 20 Apr 2019 01:38:12 +0000 (01:38 +0000)
committerMatthias Clasen <mclasen@redhat.com>
Sat, 20 Apr 2019 02:28:46 +0000 (02:28 +0000)
This was only ever implemented on X11, and
GTK is not using it at all. Relegate it to
x11-specific api.

13 files changed:
docs/reference/gdk/gdk4-sections.txt
gdk/broadway/gdksurface-broadway.c
gdk/gdksurface.c
gdk/gdksurface.h
gdk/gdksurfaceimpl.h
gdk/quartz/gdksurface-quartz.c
gdk/wayland/gdksurface-wayland.c
gdk/win32/gdksurface-win32.c
gdk/x11/gdkdrag-x11.c
gdk/x11/gdksurface-x11.c
gdk/x11/gdkx11surface.h
testsuite/reftests/messagedialog-secondarytext.ref.ui
testsuite/reftests/messagedialog-secondarytext.ui

index 41ec4d7e50bfb0205e8438fcfc3297c8d54cc58e..04b77ad3b45f7e3d2fe6b8bf4c0e78c4420801f5 100644 (file)
@@ -277,8 +277,6 @@ gdk_surface_peek_children
 gdk_surface_set_icon_name
 gdk_surface_set_transient_for
 gdk_surface_set_startup_id
-gdk_surface_set_group
-gdk_surface_get_group
 gdk_surface_set_decorations
 gdk_surface_get_decorations
 GdkWMDecoration
index a76b641a40fd7ac1b7bee855a25cb8e6a35531df..06b862c1434067317e7378cac12e812d0735257c 100644 (file)
@@ -782,22 +782,6 @@ gdk_broadway_surface_set_keep_below (GdkSurface *surface, gboolean setting)
 
 }
 
-static GdkSurface *
-gdk_broadway_surface_get_group (GdkSurface *surface)
-{
-  if (GDK_SURFACE_DESTROYED (surface) ||
-      !SURFACE_IS_TOPLEVEL (surface))
-    return NULL;
-
-  return surface;
-}
-
-static void
-gdk_broadway_surface_set_group (GdkSurface *surface,
-                                GdkSurface *leader)
-{
-}
-
 static void
 gdk_broadway_surface_set_decorations (GdkSurface      *surface,
                                       GdkWMDecoration decorations)
@@ -1357,8 +1341,6 @@ gdk_surface_impl_broadway_class_init (GdkSurfaceImplBroadwayClass *klass)
   impl_class->unfullscreen = gdk_broadway_surface_unfullscreen;
   impl_class->set_keep_above = gdk_broadway_surface_set_keep_above;
   impl_class->set_keep_below = gdk_broadway_surface_set_keep_below;
-  impl_class->get_group = gdk_broadway_surface_get_group;
-  impl_class->set_group = gdk_broadway_surface_set_group;
   impl_class->set_decorations = gdk_broadway_surface_set_decorations;
   impl_class->get_decorations = gdk_broadway_surface_get_decorations;
   impl_class->set_functions = gdk_broadway_surface_set_functions;
index f42b7c2715cc4a397fc46d6903f396f457d6731f..552d5e8bae5f939db1d4cfa19847c746ebfbaa63 100644 (file)
@@ -4628,43 +4628,6 @@ gdk_surface_set_keep_below (GdkSurface *surface,
   GDK_SURFACE_IMPL_GET_CLASS (surface->impl)->set_keep_below (surface, setting);
 }
 
-/**
- * gdk_surface_get_group:
- * @surface: a toplevel #GdkSurface
- *
- * Returns the group leader surface for @surface. See gdk_surface_set_group().
- *
- * Returns: (transfer none): the group leader surface for @surface
- **/
-GdkSurface *
-gdk_surface_get_group (GdkSurface *surface)
-{
-  return GDK_SURFACE_IMPL_GET_CLASS (surface->impl)->get_group (surface);
-}
-
-/**
- * gdk_surface_set_group:
- * @surface: a toplevel #GdkSurface
- * @leader: (allow-none): group leader surface, or %NULL to restore the default group leader surface
- *
- * Sets the group leader surface for @surface. By default,
- * GDK sets the group leader for all toplevel surfaces
- * to a global surface implicitly created by GDK. With this function
- * you can override this default.
- *
- * The group leader surface allows the window manager to distinguish
- * all surfaces that belong to a single application. It may for example
- * allow users to minimize/unminimize all surfaces belonging to an
- * application at once. You should only set a non-default group surface
- * if your application pretends to be multiple applications.
- **/
-void
-gdk_surface_set_group (GdkSurface *surface,
-                       GdkSurface *leader)
-{
-  GDK_SURFACE_IMPL_GET_CLASS (surface->impl)->set_group (surface, leader);
-}
-
 /**
  * gdk_surface_set_decorations:
  * @surface: a toplevel #GdkSurface
index 3b79cdc901103afd2423c7d7dddd1cde23d28986..88722782db2640bff2d9f3054249e969f58bf823 100644 (file)
@@ -653,11 +653,6 @@ GDK_AVAILABLE_IN_ALL
 void          gdk_surface_set_icon_name  (GdkSurface      *surface,
                                           const gchar     *name);
 GDK_AVAILABLE_IN_ALL
-void          gdk_surface_set_group      (GdkSurface      *surface,
-                                          GdkSurface      *leader);
-GDK_AVAILABLE_IN_ALL
-GdkSurface*    gdk_surface_get_group     (GdkSurface      *surface);
-GDK_AVAILABLE_IN_ALL
 void          gdk_surface_set_decorations (GdkSurface     *surface,
                                            GdkWMDecoration  decorations);
 GDK_AVAILABLE_IN_ALL
index 077ae458607a157e068aa19e704d4084041e87bc..c5bd90ae7c952e512389a9b3926309d088e66fbc 100644 (file)
@@ -159,9 +159,6 @@ struct _GdkSurfaceImplClass
                                          gboolean   setting);
   void         (* set_keep_below)       (GdkSurface *surface,
                                          gboolean   setting);
-  GdkSurface *  (* get_group)            (GdkSurface *surface);
-  void         (* set_group)            (GdkSurface *surface,
-                                         GdkSurface *leader);
   void         (* set_decorations)      (GdkSurface      *surface,
                                          GdkWMDecoration decorations);
   gboolean     (* get_decorations)      (GdkSurface       *surface,
index 14c07b0168396a69006604bcc53f51bdc2082e12..1a8e865e086df86ac1825aa2f622065fad2131c3 100644 (file)
@@ -2584,27 +2584,6 @@ gdk_quartz_surface_set_keep_below (GdkSurface *window,
   [impl->toplevel setLevel: level - (setting ? 1 : 0)];
 }
 
-static GdkSurface *
-gdk_quartz_surface_get_group (GdkSurface *window)
-{
-  g_return_val_if_fail (GDK_SURFACE_TYPE (window) != GDK_SURFACE_CHILD, NULL);
-
-  if (GDK_SURFACE_DESTROYED (window) ||
-      !SURFACE_IS_TOPLEVEL (window))
-    return NULL;
-
-  /* FIXME: Implement */
-
-  return NULL;
-}
-
-static void
-gdk_quartz_surface_set_group (GdkSurface *window,
-                             GdkSurface *leader)
-{
-  /* FIXME: Implement */       
-}
-
 static void
 gdk_quartz_surface_destroy_notify (GdkSurface *window)
 {
@@ -2724,8 +2703,6 @@ gdk_surface_impl_quartz_class_init (GdkSurfaceImplQuartzClass *klass)
   impl_class->unfullscreen = gdk_quartz_surface_unfullscreen;
   impl_class->set_keep_above = gdk_quartz_surface_set_keep_above;
   impl_class->set_keep_below = gdk_quartz_surface_set_keep_below;
-  impl_class->get_group = gdk_quartz_surface_get_group;
-  impl_class->set_group = gdk_quartz_surface_set_group;
   impl_class->set_decorations = gdk_quartz_surface_set_decorations;
   impl_class->get_decorations = gdk_quartz_surface_get_decorations;
   impl_class->set_functions = gdk_quartz_surface_set_functions;
index 9b8bc8108ec6c66625d7bc7a631eb6e43c8e2ec1..89ae48c72d1bd6493d01328d73a6161a72622750 100644 (file)
@@ -3499,18 +3499,6 @@ gdk_wayland_surface_set_keep_below (GdkSurface *surface,
 {
 }
 
-static GdkSurface *
-gdk_wayland_surface_get_group (GdkSurface *surface)
-{
-  return NULL;
-}
-
-static void
-gdk_wayland_surface_set_group (GdkSurface *surface,
-                               GdkSurface *leader)
-{
-}
-
 static void
 gdk_wayland_surface_set_decorations (GdkSurface      *surface,
                                      GdkWMDecoration  decorations)
@@ -3848,8 +3836,6 @@ _gdk_surface_impl_wayland_class_init (GdkSurfaceImplWaylandClass *klass)
   impl_class->unfullscreen = gdk_wayland_surface_unfullscreen;
   impl_class->set_keep_above = gdk_wayland_surface_set_keep_above;
   impl_class->set_keep_below = gdk_wayland_surface_set_keep_below;
-  impl_class->get_group = gdk_wayland_surface_get_group;
-  impl_class->set_group = gdk_wayland_surface_set_group;
   impl_class->set_decorations = gdk_wayland_surface_set_decorations;
   impl_class->get_decorations = gdk_wayland_surface_get_decorations;
   impl_class->set_functions = gdk_wayland_surface_set_functions;
index bc8b82470dde82c3ec2bfbe88e7f601dee7dbc2b..d5daa7cf99bb785a681ff61e8264d9abf2337e45 100644 (file)
@@ -2066,32 +2066,6 @@ gdk_win32_surface_set_icon_name (GdkSurface   *window,
 #endif
 }
 
-static GdkSurface *
-gdk_win32_surface_get_group (GdkSurface *window)
-{
-  g_return_val_if_fail (GDK_IS_SURFACE (window), NULL);
-
-  if (GDK_SURFACE_DESTROYED (window))
-    return NULL;
-
-  g_warning ("gdk_surface_get_group not yet implemented");
-
-  return NULL;
-}
-
-static void
-gdk_win32_surface_set_group (GdkSurface *window,
-                     GdkSurface *leader)
-{
-  g_return_if_fail (GDK_IS_SURFACE (window));
-  g_return_if_fail (leader == NULL || GDK_IS_SURFACE (leader));
-
-  if (GDK_SURFACE_DESTROYED (window) || GDK_SURFACE_DESTROYED (leader))
-    return;
-
-  g_warning ("gdk_surface_set_group not implemented");
-}
-
 static void
 update_single_bit (LONG    *style,
                    gboolean all,
@@ -5268,8 +5242,6 @@ gdk_surface_impl_win32_class_init (GdkSurfaceImplWin32Class *klass)
   impl_class->unfullscreen = gdk_win32_surface_unfullscreen;
   impl_class->set_keep_above = gdk_win32_surface_set_keep_above;
   impl_class->set_keep_below = gdk_win32_surface_set_keep_below;
-  impl_class->get_group = gdk_win32_surface_get_group;
-  impl_class->set_group = gdk_win32_surface_set_group;
   impl_class->set_decorations = gdk_win32_surface_set_decorations;
   impl_class->get_decorations = gdk_win32_surface_get_decorations;
   impl_class->set_functions = gdk_win32_surface_set_functions;
index 2a7e705c237a1c162288d4f4625480c3a3bac862..43779168ff6c01d5426af7793cfdbb24745cb137 100644 (file)
@@ -2110,8 +2110,8 @@ _gdk_x11_surface_drag_begin (GdkSurface         *surface,
   x11_drag->protocol = GDK_DRAG_PROTO_XDND;
   x11_drag->actions = actions;
   x11_drag->ipc_surface = ipc_surface;
-  if (gdk_surface_get_group (surface))
-    gdk_surface_set_group (x11_drag->ipc_surface, surface);
+  if (gdk_x11_surface_get_group (surface))
+    gdk_x11_surface_set_group (x11_drag->ipc_surface, surface);
   gdk_surface_show (x11_drag->ipc_surface);
 
   x11_drag->drag_surface = create_drag_surface (display);
index aa5eb9b5a453172ad8afb97cca242f8978fc863c..e605710010c60b3fd152693dd8a02f475c9ffa25 100644 (file)
@@ -3363,7 +3363,7 @@ gdk_x11_surface_set_keep_below (GdkSurface *surface, gboolean setting)
                                 setting ? GDK_SURFACE_STATE_BELOW : 0);
 }
 
-static GdkSurface *
+GdkSurface *
 gdk_x11_surface_get_group (GdkSurface *surface)
 {
   GdkToplevelX11 *toplevel;
@@ -3377,9 +3377,9 @@ gdk_x11_surface_get_group (GdkSurface *surface)
   return toplevel->group_leader;
 }
 
-static void
+void
 gdk_x11_surface_set_group (GdkSurface *surface,
-                         GdkSurface *leader)
+                           GdkSurface *leader)
 {
   GdkToplevelX11 *toplevel;
   
@@ -4679,8 +4679,6 @@ gdk_surface_impl_x11_class_init (GdkSurfaceImplX11Class *klass)
   impl_class->unfullscreen = gdk_x11_surface_unfullscreen;
   impl_class->set_keep_above = gdk_x11_surface_set_keep_above;
   impl_class->set_keep_below = gdk_x11_surface_set_keep_below;
-  impl_class->get_group = gdk_x11_surface_get_group;
-  impl_class->set_group = gdk_x11_surface_set_group;
   impl_class->set_decorations = gdk_x11_surface_set_decorations;
   impl_class->get_decorations = gdk_x11_surface_get_decorations;
   impl_class->set_functions = gdk_x11_surface_set_functions;
index fcd6a8006d352ebaa54894fa1b297aed88b417c9..844a2de9cd4285eb05d8f4f0fb3eafab512ed79f 100644 (file)
@@ -115,6 +115,13 @@ GDK_AVAILABLE_IN_ALL
 void gdk_x11_surface_set_urgency_hint      (GdkSurface *surface,
                                             gboolean    urgent);
 
+GDK_AVAILABLE_IN_ALL
+void          gdk_x11_surface_set_group    (GdkSurface *surface,
+                                            GdkSurface *leader);
+GDK_AVAILABLE_IN_ALL
+GdkSurface *  gdk_x11_surface_get_group    (GdkSurface *surface);
+
+
 G_END_DECLS
 
 #endif /* __GDK_X11_SURFACE_H__ */
index 5856b837fed62653b314de19ef9170473532957b..584ad22b198c183f083e119cdcf9e77014f6cb03 100644 (file)
@@ -3,7 +3,6 @@
   <object class="GtkMessageDialog" id="messagedialog1">
     <property name="type">popup</property>
     <property name="type_hint">dialog</property>
-    <property name="skip_taskbar_hint">1</property>
     <property name="buttons">ok</property>
     <property name="text" translatable="yes">Text</property>
     <property name="secondary_text" translatable="yes">Secondary text #5</property>
index f25df315158c293014b0da19e9c32824a7c34093..8f97175665513e39d48ca46175f4ee9acb632213 100644 (file)
@@ -3,7 +3,6 @@
   <object class="GtkMessageDialog" id="messagedialog1">
     <property name="type">popup</property>
     <property name="type_hint">dialog</property>
-    <property name="skip_taskbar_hint">1</property>
     <property name="buttons">ok</property>
     <property name="text" translatable="yes">Text</property>
     <property name="secondary_text" translatable="yes">Secondary text #1</property>